import Vue, { computed } from 'vue'
import VueRouter from 'vue-router'
import Login from '@/views/Login.vue'
import Login2 from '@/views/Login2.vue'
import Home from '@/components/Home'
import Info from '@/views/InfoPage'
import Singer from '@/views/SingerPage'
import SongList from '@/views/SongListPage'
import Consumer from '@/views/ConsumerPage'
import AddSinger from '@/views/singer/addSinger'
import ManagerSong from '@/views/songs/songs'
import addSong  from '@/views/songs/addSong.vue'
import listSong from '@/views/songList/listSong'
import addConsumer from '@/views/consumer/addConsumer'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'home',
    component: Login
  },
  {
    path: '/Home',
    name:'home',
    component: Home,
    children:[
      {
        path:'/Info',
        component: Info
      },
      {
        path:'/Singer',
        component: Singer
      },
      {
        path:'/SongList',
        component: SongList
      },
      {
        path:'/Consumer',
        component: Consumer
      },
      {
        path:'/AddSinger',
        component: AddSinger
      },
      {
        path:'/ManagerSong',
        component: ManagerSong
      },
      {
        path:'/addSong',
        component: addSong
      },
      {
        path:'/listSong',
        component: listSong
      },
      {
        path:'/addConsumer',
        component: addConsumer
      }
    ]
  }
]


const router = new VueRouter({
  routes
})

export default router
